<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link href="/Css/tools.css" rel="stylesheet" type="text/css"/>
<title>墙砖计算器_大泉州房产</title>
<script language='javascript' type='text/javascript'>
<!--
function IsDigit(cCheck)
{
 return ((('0'<=cCheck) && (cCheck<='9'))||cCheck=='.');
 }
function CheckNum(charValue,alertValue,obj)
{
	for(var iIndex=0;iIndex<charValue.length;iIndex++)
	{
		var cCheck=charValue.charAt(iIndex);
		if(!IsDigit(cCheck))
		{
		alert(alertValue);
		obj.focus();
		return false;
		}
	}
}
function GoTo(URL){
	if(location.href.toLowerCase().indexOf(URL.toLowerCase())<0) location.href = URL;
}
//-->
</script>
<SCRIPT language=JavaScript type=text/JavaScript>
<!--
function wall_brick(form)
{
 //检查输入
 if(checkInput(form)==false) return;
 var room_long=0,room_width=0,room_height=0,door_height=0,door_width=0,door_num=0;
 var window_height=0,window_width=0,window_num=0,brick_long=0,brick_width=0;
 var bricknum=0;
 var rate=1.05;
 //给各个变量赋值
 room_long=form.room_long.value*1000;
 room_width=form.room_width.value*1000;
 room_height=form.room_height.value*1000;
 
 door_height=form.door_height.value*1000;
 door_width=form.door_width.value*1000;
 door_num=form.door_num.value;
 
 window_height=form.window_height.value*1000;
 window_width=form.window_width.value*1000;
 window_num=form.window_num.value;
 
 brick_long=form.brick_long.value;
 brick_width=form.brick_width.value;
 
 //开始计算
 //用砖数量（块数）=[（房间的长度÷砖长）×（房间高度÷砖宽）×2+ 
 //（房间的宽度÷砖长）×（房间高度÷砖宽）×2—（窗户的长度÷砖长）×
 //（窗户的宽度÷砖宽）×个数—（门的长度÷砖长）×（门的宽度÷砖宽）×个数]×1.05
 bricknum=(room_long/brick_long)*(room_height/brick_width)*2;
 bricknum= parseFloat(bricknum)+parseFloat((room_width/brick_long)*(room_height/brick_width) *2);
 bricknum=parseFloat(bricknum)- parseFloat((window_height/brick_long)*(window_width/brick_width)*window_num);
 bricknum=parseFloat(bricknum)-parseFloat((door_height/brick_long)*(door_width/brick_width)*door_num);
 bricknum=Math.round(bricknum*1.05);
 
 form.wallbricknum.value=bricknum;
}
function checkInput(wallbrickfrm)
{
	if(wallbrickfrm.room_long.value==""){
		alert("请输入房间长度");
		wallbrickfrm.room_long.focus();
		return false;
		}
	if(CheckNum(wallbrickfrm.room_long.value,"房间长度只能输入数字格式！",wallbrickfrm.room_long)==false)
	return false;

	if(wallbrickfrm.room_width.value==""){
		alert("请输入房间宽度");
		wallbrickfrm.room_width.focus();
		return false;
		}
	if(CheckNum(wallbrickfrm.room_width.value,"房间宽度只能输入数字格式！",wallbrickfrm.room_width)==false)
	return false;
	if(wallbrickfrm.room_height.value==""){
		alert("请输入房间高度");
		wallbrickfrm.room_height.focus();
		return false;
		}
	if(CheckNum(wallbrickfrm.room_height.value,"房间高度只能输入数字格式！",wallbrickfrm.room_height)==false)
	return false;
	if(wallbrickfrm.door_height.value==""){
		alert("请输入房门高度");
		wallbrickfrm.door_height.focus();
		return false;
		}
	if(CheckNum(wallbrickfrm.door_height.value,"房门高度只能输入数字格式！",wallbrickfrm.door_height)==false)
	return false;
	if(wallbrickfrm.door_width.value==""){
		alert("请输入房门宽度");
		wallbrickfrm.door_width.focus();
		return false;
		}
	if(CheckNum(wallbrickfrm.door_width.value,"房门宽度只能输入数字格式！",wallbrickfrm.door_width)==false)
	return false;

	if(wallbrickfrm.door_num.value==""){
		alert("请输入房门扇数");
		wallbrickfrm.door_num.focus();
		return false;
		}
	if(CheckNum(wallbrickfrm.door_num.value,"房门扇数只能输入数字格式！",wallbrickfrm.door_num)==false)
	return false;
		
	if(wallbrickfrm.window_height.value==""){
		alert("请输入窗户高度");
		wallbrickfrm.window_height.focus();
		return false;
		}
	if(CheckNum(wallbrickfrm.window_height.value,"窗户高度只能输入数字格式！",wallbrickfrm.window_height)==false)
	return false;
	if(wallbrickfrm.window_width.value==""){
		alert("请输入窗户宽度");
		wallbrickfrm.window_width.focus();
		return false;
		}
	if(CheckNum(wallbrickfrm.window_width.value,"窗户宽度只能输入数字格式！",wallbrickfrm.window_width)==false)
	return false;
	if(wallbrickfrm.window_num.value==""){
		alert("请输入窗户扇数");
		wallbrickfrm.window_num.focus();
		return false;
		}
	if(CheckNum(wallbrickfrm.window_num.value,"窗户扇数只能输入数字格式！",wallbrickfrm.window_num)==false)
	return false;
		
	if(wallbrickfrm.brick_long.value==""){
		alert("请输入墙砖长度");
		wallbrickfrm.brick_long.focus();
		return false;
		}
	if(CheckNum(wallbrickfrm.brick_long.value,"墙砖长度只能输入数字格式！",wallbrickfrm.brick_long)==false)
	return false;
	if(wallbrickfrm.brick_width.value==""){
		alert("请输入墙砖宽度");
		wallbrickfrm.brick_width.focus();
		return false;
		}
	if(CheckNum(wallbrickfrm.brick_width.value,"墙砖宽度只能输入数字格式！",wallbrickfrm.brick_width)==false)
	return false;
}
function autoinput(form)
{
	//alert(form.bricktype.value);
	switch(parseInt(form.bricktype.value))
	{
		case 0:

		     form.brick_long.value=200;
			 form.brick_width.value=200;
		     break;
		case 1:
		     form.brick_long.value=300;
			 form.brick_width.value=300;
		     break;
		case 2:
			 form.brick_long.value=400;
			 form.brick_width.value=400;
		     break;
		case 3:
			 form.brick_long.value=500;
			 form.brick_width.value=500;
		     break;
		case 4:
			 form.brick_long.value=600;
			 form.brick_width.value=600;
			 break;
		case 5:
			 form.brick_long.value=300;
			 form.brick_width.value=200;
			 break;
		case 6:
			 form.brick_long.value=250;
			 form.brick_width.value=330;
			 break;
		case 7:
			 form.brick_long.value=300;
			 form.brick_width.value=450;
			
	}
}
//-->
</SCRIPT>
</HEAD>
<BODY>
<script type="text/javascript" src="/htmls/tools/images/js1.js">
//<!--

</script>
<script type="text/javascript">
//<!--
_S_pSt("");
//-->
</script>
<div class="pg">
  <!--上面-->
  <div class="logo1"><img src="/images/v1/common/logo.gif" /></div>
  <div class="logo2"><a href="/">首页</a><a href="/login.html">登录</a><a href="/reg.html">注册</a></div>
  <div class="dh"><img src="/images/v1/tools/ht.gif" /></div>
  <div class="dh1"><a href="/">房产首页</a>&gt;<a href="/jiaju.html">家装装修</a>&gt;<a href="/htmls/tools/jz1.htm">家装计算器</a>&gt;<a href="/htmls/tools/jz1.htm">墙砖计算器</a> </div>
  <!--中间-->
  <div class="main">
    <!--左边-->
    <div class="left">
      <div class="left1" style="margin-top:5px"><a href="/htmls/tools/jz1.htm" style="font-weight:bold">墙砖计算器</a></div>
      <div class="left1" style="margin-top:10px"><a href="/htmls/tools/jz2.htm" >地砖计算器</a></div>
      <div class="left1" style="margin-top:10px"><a href="/htmls/tools/jz3.htm">地板计算器</a></div>
      <div class="left1" style="margin-top:10px"><a href="/htmls/tools/jz4.htm">壁纸计算器</a></div>
      <div class="left1" style="margin-top:10px"><a href="/htmls/tools/jz5.htm">涂料计算器</a></div>
      <div class="left1" style="margin-top:10px"><a href="/htmls/tools/jz6.htm">窗帘计算器</a> </div>
    </div>
    <!--右边-->
    <div class="right1">
      <div class="r1">墙砖计算器</div>
      <div class="r2">
        <table width="500">
          <tr>
            <td><form name="wallbrickfrm" action="" method="post">
                <table width="476" align="center" cellspacing="0" style="margin-top:10px;">
                  <tr>
                    <td class="title">1、请输入居室信息</td>
                  </tr>
                  <tr>
                    <td class="elem">房间长度
                      <INPUT name="room_long" >
                      米 </td>
                  </tr>
                  <tr>
                    <td class="elem">房间宽度
                      <INPUT name="room_width" >
                      米 </td>
                  </tr>
                  <tr>
                    <td class="elem">房间高度
                      <INPUT  name="room_height">
                      米 </td>
                  </tr>
                  <tr>
                    <td class="title">2、请输入室内门窗信息</td>
                  </tr>
                  <tr>
                    <td class="elem">房门高度
                      <INPUT  name="door_height">
                      米</td>
                  </tr>
                  <tr>
                    <td class="elem">窗户高度
                      <INPUT  name="window_height">
                      米 </td>
                  </tr>
                  <tr>
                    <td class="elem">房门宽度
                      <INPUT  name="door_width">
                      米 </td>
                  </tr>
                  <tr>
                    <td class="elem">窗户宽度
                      <INPUT  name="window_width">
                      米 </td>
                  </tr>
                  <tr>
                    <td class="elem">房门扇数
                      <INPUT  name="door_num">
                      个 </td>
                  </tr>
                  <tr>
                    <td class="elem">窗户扇数
                      <INPUT  name="window_num">
                      个</td>
                  </tr>
                  <tr>
                    <td class="title">3、请输入配备的单块墙砖信息</td>
                  </tr>
                  <tr>
                    <td class="elem">墙砖长度
                      <INPUT  name="brick_long" value="200">
                      毫米 </td>
                  </tr>
                  <tr>
                    <td class="elem">墙砖宽度
                      <INPUT  name="brick_width" value="200">
                      毫米 </td>
                  </tr>
                  <tr>
                    <td class="elem"><span style="color:#FF6D11;">或选择标准规格的墙砖</span>
                      <SELECT 
                  onchange="autoinput(this.form)" name="bricktype">
                        <OPTION 
                    value="0" selected>200x200</OPTION>
                        <OPTION 
                    value="1">300x300</OPTION>
                        <OPTION value="2">400x400</OPTION>
                        <OPTION value="3">500x500</OPTION>
                        <OPTION 
                    value="4">600x600</OPTION>
                        <OPTION value="5">300x200</OPTION>
                        <OPTION value="6">250x330</OPTION>
                        <OPTION 
                    value=7>300x450</OPTION>
                      </SELECT>
                      毫米 </td>
                  </tr>
                  <tr>
                    <td height="7"></td>
                  </tr>
                  <tr>
                    <td height="21" align="center" bgcolor="#fcf2d5"><strong>计算结果</strong></td>
                  </tr>
                  <tr>
                    <td height="1"></td>
                  </tr>
                  <tr>
                    <td height="1" background="/images/v1/tools/12.gif"></td>
                  </tr>
                  <tr>
                    <td height="7"></td>
                  </tr>
                  <tr>
                    <td class="elem">你需要的墙砖数量是
                      <INPUT 2 name="wallbricknum">
                      块 </td>
                  </tr>
                  <tr>
                    <td height=35 align="center"><input type="button" onclick="wall_brick(this.form)" value=" 计算">
                      &nbsp;
                      <input type="reset" value=" 重算">
                    </td>
                  </tr>
                </table>
              </form></td>
          </tr>
        </table> </div>
        <div style="background-color:#fcf2d5;padding:10px 20px 10px 20px;color:#666; width:547; clear:both"> <span style="color:#ff5500;">提醒：</span>该墙砖计算器提供的结果仅供参考。购买时请以专业厂商提供的数据为准。 </div>
     
    </div>
  </div>
  <!--注脚-->
  <div class="footer">
    <div class="link3" align="center">
      <div><a href="/">QZFC简介</a><span>|</span><a href="/">用户注册</a><span>|</span>
        <a href="/">
        隐私声明</a><span>|</span><a href="/">服务条款</a><span>|</span><a href="/">合作加盟</a><span>|</span><a href="/">联系我们</a><span>|</span><a href="/">友情链接</a><span>|</span><a href="/">帮助中心</a></div>
      <div>中国·福建·泉州·丰泽区泉秀路宝成大厦1#&nbsp;&nbsp;&nbsp;客服电话：0595-24663003&nbsp;&nbsp;&nbsp;传真: 0595-22164848</div>
      <div>大泉州房产网 qzfc.com  版权所有 © 2008-2009</div>
    </div>
  </div>
</div>
</body>
</html>
